Skip to content

fix(submitter): submit_batch/2 crashed on every call (MatchError)#48

Merged
hyperpolymath merged 2 commits into
mainfrom
fix/submit-batch-matcherror
Jul 9, 2026
Merged

fix(submitter): submit_batch/2 crashed on every call (MatchError)#48
hyperpolymath merged 2 commits into
mainfrom
fix/submit-batch-matcherror

Conversation

@hyperpolymath

Copy link
Copy Markdown
Owner

Bug

FeedbackATron.Submitter.submit_batch/2 — a public API — raised MatchError on every call with a non-empty issue list, crashing the Submitter GenServer.

handle_call({:submit_batch, ...}) maps over issues and matches the inner handle_call({:submit, ...}) against a bare {:ok, id, result}. But handle_call returns a GenServer {:reply, {:ok, id, result}, state} 3-tuple — so the match always failed.

Found while running the suite during pipeline work (the existing test submitter_test.exs submit_batch/2 batch submission processes multiple issues was red).

Fix

Destructure the reply payload: {:reply, {:ok, id, result}, _new_state} = handle_call(...).

Verification

Previously-failing test now passes; full suite green (139 tests, 0 failures).

🤖 Generated with Claude Code

handle_call({:submit_batch, ...}) matched the inner
handle_call({:submit, ...}) against a bare {:ok, id, result}, but that
call returns a GenServer {:reply, {:ok, id, result}, state} 3-tuple — so
submit_batch/2 raised MatchError for any non-empty issue list, taking down
the Submitter GenServer. Destructure the reply payload instead.

The pre-existing test 'submit_batch/2 batch submission processes multiple
issues' now passes; full suite green (139 tests, 0 failures).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@hyperpolymath
hyperpolymath marked this pull request as ready for review July 9, 2026 08:40
@hyperpolymath
hyperpolymath merged commit e20a24b into main Jul 9, 2026
@hyperpolymath
hyperpolymath deleted the fix/submit-batch-matcherror branch July 9, 2026 08:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant